package main.java.FSMDE.validation.rules;

import main.java.ERMDE.validation.ValidationType;
import main.java.FSMDE.models.Diagram;
import main.java.FSMDE.models.Transition;
import main.java.FSMDE.validation.IValidationEntry;


public class TransitionWithoutSourceValidationEntry implements IValidationEntry {

	private Diagram diagram;
	private Transition transition;

	public TransitionWithoutSourceValidationEntry(Diagram diagram, Transition transition) {
		this.diagram = diagram;
		this.transition = transition;
	}

	@Override
	public Diagram getDiagram() {
		return this.diagram;
	}

	@Override
	public String getMessage() {
		return String.format("Transition '%s' does not have source interface set.", transition);
	}

	@Override
	public ValidationType getType() {
		return ValidationType.ERROR;
	}

}
